]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
shellDBus: Actually make ScreenTransitionAsync async
authorMarco Trevisan (Treviño) <mail@3v1n0.net>
Mon, 28 Mar 2022 13:25:41 +0000 (15:25 +0200)
committerMarco Trevisan (Treviño) <mail@3v1n0.net>
Mon, 28 Mar 2022 13:36:18 +0000 (15:36 +0200)
We called such function async but we didn't awaited for the
checkInvocation result in the proper way.

So on failure the shell would report an unhandled promise rejection.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2258>

js/ui/shellDBus.js

index 8faa112eaf6ccbf31f400a20aaffa0ad8d6dc016..edc16eb872b6cf2c16fae52a0596236c063f0d4c 100644 (file)
@@ -253,9 +253,9 @@ var GnomeShell = class {
         invocation.return_value(GLib.Variant.new('(b)', [ungrabSucceeded]));
     }
 
-    ScreenTransitionAsync(params, invocation) {
+    async ScreenTransitionAsync(params, invocation) {
         try {
-            this._senderChecker.checkInvocation(invocation);
+            await this._senderChecker.checkInvocation(invocation);
         } catch (e) {
             invocation.return_gerror(e);
             return;